The voice processing industry is moving from ‘circuit-switched’ voice communication to ‘packetized’ voice communication. In technical terms this move is from digitized voice sent sample by sample at a fixed rate over dedicated digital channels to digitized voice collected together in packets of data and then sent over a communication channel that may be shared between large numbers of individual users. The Internet Engineering Task Force (IETF) have developed protocols to define how voice should be sent and received over packetized voice channels and the most well known of these is Real Time Protocol (RTP) that was defined in IETF Request for Comments (RFC) 3550.
RFC 3550 defines the way in which voice is sent using RTP over a User Datagram Protocol (UDP) connection rather than a TCP connection. TCP is not appropriate for real-time communication as the need to retain all packets at the transmitter until acknowledged by the receiver would cause unacceptable memory, latency and processing overheads. UDP is not inherently a reliable protocol as there are no built-in mechanisms to prevent voice packets being a) lost completely or b) received out of order. However, using some header fields added to the basic payload, and making the assumption that voice is a QUALITITIVE data type where absolute perfection is not required, RTP provides the means by which an original audio stream sent using UDP can be reasonably recreated in the presence of missing, delayed and out of order packets.
Processing of incoming and outgoing audio packets to support RTP is a complex matter, especially when some other requirements are taken into account. These include: 1) the ability to specify the encoding (codec) to be used both by the application and the actual RTP data itself; 2) the need to be able to dynamically change operating parameters based upon, for example, packet loss; and 3) the requirement to be able to send the recovered audio from an incoming RTP stream to multiple sinks (e.g. to a voice recorder, a voice recogniser and a debug recording tool).